<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        #box1 {
            width: 202px;
            height: 202px;
            padding: 50px;
            border: 1px solid #000;
        }
        
        #box2 {
            width: 100px;
            height: 100px;
            padding: 50px;
            border: 1px solid #000;
        }
        
        #box3 {
            width: 100px;
            height: 100px;
            border: 1px solid #000;
        }
    </style>
</head>

<body>
    <div id="box1">
        <div id="box2">
            <div id="box3">

            </div>
        </div>
    </div>
    <script>
        var box1 = document.getElementById("box1");
        var box2 = document.getElementById("box2");
        var box3 = document.getElementById("box3");
        //   box1.onclick = function() {
        //       alert('A');
        //   }
        //   box1.onclick = function() {
        //       alert('B '); //B
        //   }


        box2.addEventListener("click", function() {
            alert('C ');
        }, false)

        box2.addEventListener("click", function() {
            alert('D '); //先C再D
        }, false)
    </script>
</body>

</html>